package com.trkj.dao.jpa;

import java.util.List;

import org.springframework.data.domain.Pageable;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.CrudRepository;

import com.trkj.pojos.LmbAllotApply;
import com.trkj.pojos.YzrStorehouse;

public interface LmbAllotApplyDAO extends CrudRepository<LmbAllotApply,String>{
	@Query("select max(c.allotId) from LmbAllotApply c where c.allotId like ?1%")
    public String findMaxID(String a);
	
	@Query("select a from LmbAllotApply a order by a.allotId desc")
	public List<LmbAllotApply> findAll(Pageable pageable);
	
	@Query("select count(*) from LmbAllotApply a ")
	public long countfindAll();
	
	@Query("select a from LmbAllotApply a order by a.allotId desc")
	public List<LmbAllotApply> findAllApply();
	
}
